GXDrawBitmap
You can use theGXDrawBitmap
function to draw a bitmap without encapsulating the bitmap geometry in a bitmap shape.
void GXDrawBitmap(const gxBitmap *data, const gxPoint *position);
data
- A pointer to a
gxBitmap
structure that specifies information about the bitmap you want to draw.position
- A pointer to a
gxPoint
structure which indicates the position to draw the bitmap.DESCRIPTION
TheGXDrawBitmap
function allows you to draw a bitmap without having to create a bitmap shape yourself. Instead, you create agxBitmap
structure specifying the bitmap you want to draw and agxPoint
structure indicating the position of the bitmap, and then you pass a pointer to these structures in thedata
andposition
parameters, respectively.The
GXDrawBitmap
function calls theGXNewBitmap
function to create a temporary bitmap shape using the values specified in these structures and the style, ink and transform of the default bitmap shape. Then theGXDrawBitmap
function draws the bitmap shape using theGXDrawShape
function.For information about how QuickDraw GX creates bitmap shapes using the values you provide in the fields of the
gxBitmap
structure, see the description of theGXNewBitmap
function on page 5-66.ERRORS, WARNINGS, AND NOTICES
Errors out_of_memory shape_is_nil parameter_is_nil size_of_bitmap_exceeds_implementation_limit parameter_is_nil (debugging version) invalid_pixelSize (debugging version) bitmap_height_negative (debugging version) bitmap_width_negative (debugging version) bitmap_height_negative (debugging version) bitmap_rowBytes_negative (debugging version) bitmap_rowBytes_too_small (debugging version) bitmap_rowBytes_not_aligned (debugging version) bitmap_ptr_not_aligned (debugging version) bitmap_rowBytes_must_be_specified_for_user_image_buffer (debugging version) colorSpace_out_of_range (debugging version) Warnings shape_access_not_allowed (debugging version) SEE ALSO
For examples of this function, see "Creating Black-and-White Bitmaps" beginning on page 5-15.For information about the
gxBitmap
structure, see "The Bitmap Geometry Structure" beginning on page 5-62.To encapsulate a bitmap geometry in a bitmap shape, use the
GXNewBitmap
function, which is described on page 5-66.To draw a bitmap once you've encapsulated it in a bitmap shape, use the
GXDrawShape
function, which is described in the "Shape Objects" chapter of Inside Macintosh: QuickDraw GX Objects.
Main | Page One | What's New | Apple Computer, Inc. | Find It | Contact Us | Help